const path = require('path')

// 测试地址
// let cloudUrl = 'https://tcb-rxeszamj94676b-6d6j813d8fcf0.service.tcloudbase.com'
// 正式地址
let cloudUrl = 'https://test.the3dspace.cn'

module.exports = {
	uniIDConfigMerchant: {
		"passwordSecret": "d3ds-mall-nb",
		"tokenSecret": "d3ds-mall-nb",
		"tokenExpiresIn": 172800,
		"tokenExpiresThreshold": 600,
		"passwordErrorLimit": 6,
		"bindTokenToDevice": false,
		"passwordErrorRetryTime": 3600,
		"autoSetInviteCode": false,
		"forceInviteCode": false,
		"preferedAppPlatform": "app",
		"app-plus": {
			"tokenExpiresIn": 2592000,
			"oauth" : {
				"weixin" : {
					"appid" : "weixin appid",
					"appsecret" : "weixin appsecret"
				}
			}
		},
		"mp-weixin": {
			"oauth" : {
				"weixin" : {
					"appid" : "wxa7e5444036dea6af",
					"appsecret" : "4af340b2fc0219f19def7d57deacc601"
				}
			}
		},
		"mp-alipay": {
			"oauth" : {
				"alipay" : {
					"appid" : "alipay appid",
					"privateKey" : "alipay privateKey"
				}
			}
		},
		"service": {
			"sms": {
				"name": "DCloud",
				"codeExpiresIn": 300,
				"smsKey": "your sms key",
				"smsSecret": "your sms secret"
			}
		}
	},
	// 测试、正式地址
	CLOUDURL: cloudUrl,
	// 微信小程序端对应的微信支付及登录配置配置
	wxConfigMp: {
		appId: 'wx609a0a547e98415d',
		secret: '64d84d1c8760e800fdc0d07fe2d82ed4',
		mchId: '1617785987',
		key: 'OjkIujuhUJRQgbvH56gQnbn7ujfsvLab',
	},
	// App端对应的微信支付配置
	wxConfigApp: {
		appId: '',
		mchId: '',
		key: '',
	},
	// 微信PC网站支付
	wxConfigH5: {
		appId: '',
		mchId: '',
		key: '',
	},
	// 支付宝小程序端对应的支付宝支付及登录配置
	aliConfigMp: {
		mchId: "",
		appId: "",
		alipayPublicKey: "",
		privateKey: "",
	},
	// App端对应的支付宝支付配置
	aliConfigApp: {
		mchId: "",
		appId: "",
		alipayPublicKey: "",
		privateKey: "",
	},
	// 公众号配置
	wxPubConfig: {
		appId: "wx0221cfcb91b1286d",
		appSecret: "dcfd4e317b00c3f69dbebde7dd525c37"
	},
	// 并发锁配置
	redlockConfig: {
		resourceKeyMap: {
			orderChargeoff: "locks:order:322458",
			genOrder: "locks:order:322457",
			genTicketCode: "locks:order:322456",
			orderRefund: "locks:order:322459",
			orderTimeout: "locks:order:322460"
		}
	}
}
